package com.haiyou.common.system;

import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.TimeUnit;

import org.springframework.util.StringUtils;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;
import com.haiyou.common.constants.ServerConfigConstants;
import com.haiyou.common.exception.ServiceException;
import com.haiyou.common.util.string.StringFormatUitls;

import lombok.extern.slf4j.Slf4j;

/**
 * 
 * @Description: 配置总入口
 * @author xingyuan
 * @date 2022年2月15日 下午5:08:28
 */
@Slf4j
public class Properties {
	
	/**
	 * 部分需要解析的部分缓存
	 */
	private static Map<String, Object> cache = Maps.newConcurrentMap();
	
	private static final Set<String> default_set = Sets.newHashSet();
	
	public static void restCache() {
		cache = Maps.newConcurrentMap();
	}

	/**
	 * 文件模式
	 */
	public static final String file = "file";
	
	/**
	 * apollo 模式 目前未接入
	 */
	public static final String apollo = "apollo";
	
	/**
	 * spring Environment
	 */
	public static final String spring = "spring";
	
	
	/**
	 * 服务器节点id
	 * @return
	 */
	public static Long server_node_id() {
		return getConfigProperties().getLong("server.node.id",-1);
	}
	
	/**
	 * 获取配置
	 * @return
	 */
	private static ConfigProperties getConfigProperties() {
		
		//默认文件模式
		String key = ConfigProperties.getConfigProperties(file).getString("config.properties.type",file);		
		
		return ConfigProperties.getConfigProperties(key);
	}

	public static boolean game_ai(){
		return getConfigProperties().getBoolean("game.ai",false);
	}
	
	public static String game_ws_address_default() {
		return getConfigProperties().getString("game.ws.address.default", "");
	}
	
	public static String game_ws_address_server_id(int serverId) {
		return getConfigProperties().getString(StringFormatUitls.format("game.ws.address.{}", serverId)
				, game_ws_address_default());
	}
	
	public static String getString(String key,String defaultValue) {
		return getConfigProperties().getString(key, defaultValue);
	}
	
	public static int getInt(String key,int defaultValue) {
		return getConfigProperties().getInt(key, defaultValue);
	}
	
	public static boolean getBoolean(String key,boolean defaultValue) {
		return getConfigProperties().getBoolean(key, defaultValue);
	}
	
	/**
	 * 是否开启远程配置
	 * @return
	 */
	public static boolean spring_cloud_config_enabled() {
		return getConfigProperties().getBoolean("spring.cloud.config.enabled", false);
	}
	
	/**
	 * 配置文件 profile
	 * @return
	 */
	public static String spring_cloud_config_profile() {
		return getConfigProperties().getString("spring.cloud.config.profile", "dev");
	}
	
	/**
	 * 获取配置文件 uri
	 * @return
	 */
	public static String spring_cloud_config_uri() {
		return getConfigProperties().getString("spring.cloud.config.uri", "http://localhost:8080");
	}
	
	
	/**
	 * 获取 actuator ip 白名单列表
	 * @return
	 */
	public static List<String> actuator_ip_white(){
		
		String ips = getConfigProperties().getString("actuator.ip.white", "127.0.0.1");
		
		String[] strs = ips.split("[,]");
		
		List<String> list = Lists.newArrayList();

		for (int i = 0; i < strs.length; i++) {
			String str = strs[i];
			
			if(!StringUtils.hasLength(str)) {
				continue;
			}
			list.add(str);
		}
		
		return list;
	}

	public static boolean replace_table_column() {
		return getConfigProperties().getBoolean("replace.table.column",false);
	}
	
	/**
	 * 慢读
	 * @return
	 */
	public static int slowly_read() {
		return getConfigProperties().getInt("slowly.read", 50);
	}
	
	/**
	 * 慢写
	 * @return
	 */
	public static int slowly_write() {
		return getConfigProperties().getInt("slowly.write", 100);
	}
	
	/**
	 * 慢执行
	 * @return
	 */
	public static int slowly_execute() {
		return getConfigProperties().getInt("slowly.execute", 200);
	}
	
	/**
	 * 慢执行mysql
	 * @return
	 */
	public static int slowly_mysql_execute() {
		return getConfigProperties().getInt("slowly.mysql.execute", 300);
	}
	
	/**
	 * sql 批量执行
	 * @return
	 */
	public static int sql_batchNum() {
		return getConfigProperties().getInt("sql.batchNum", 1000);
	}
	
	/**
	 * 定时器线程数
	 * @return
	 */
	public static int thread_num_schedule() {
		return getConfigProperties().getInt("scheduled.thread.num", 2);
	}

	/**
	 * redis 配置文件路径
	 * @return
	 */
	public static String redis_config_path() {
		return getConfigProperties().getString("redis.config.path", "redis");
	}
	
	
	

	/**
	 * 获取绝对路径 redis.config.path
	 * @return
	 */
	public static String redis_config_path_ResourcesAbsolutePath() {
		return getConfigProperties().getResourcesAbsolutePath("redis.config.path", "redis");
	}


	/**
	 * mysql 配置文件路径
	 * @return
	 */
	public static String mysql_config_path() {
		return getConfigProperties().getString("mysql.config.path", "mysql");
	}
	
	
	/**
	 * 获取日志级别
	 * @return
	 */
	public static String log_level() {
		return getConfigProperties().getString("log.level", "info");
	}

	/**
	 * 获取绝对路径 mysql.config.path
	 * @return
	 */
	public static String mysql_config_path_ResourcesAbsolutePath() {
		return getConfigProperties().getResourcesAbsolutePath("mysql.config.path", "mysql");
	}
	
	
	public static String mongo_config_path_ResourcesAbsolutePath() {
		return getConfigProperties().getResourcesAbsolutePath("mongo.config.path", "mongo");
	}
	
	/**
	 * 是否自动创建数据库
	 * @return
	 */
	public static boolean database_auto_create() {
		return getConfigProperties().getBoolean("database.auto.create",true);
	}
	
	
	/**
	 * ftp 服务器端口号
	 * @return
	 */
	public static int ftp_port() {
		return getConfigProperties().getInt("ftp.port", 21);
	}
	
	
	/**
	 * ftp 服务路径
	 * @return
	 */
	public static String ftp_server_path() {
		return getConfigProperties().getString("ftp.server.path", SystemProperties.getResourcesAbsolutePath());
	}

	public static Integer platform_id() {
		return	getConfigProperties().getInt("platform.id", 1000);
	}
	
	public static Integer env_id() {
		return	getConfigProperties().getInt("env.id", 1000);
	}
	
	public static int lock_wait_time(String keyPrefix) {
		return getConfigProperties().getInt(keyPrefix + ".lockWaitTime", 3000);
	}

	public static int lock_lease_time(String keyPrefix) {
		return getConfigProperties().getInt(keyPrefix + ".lockLeaseTime", 3000);
	}

	public static String lock_time_unit(String keyPrefix) {
		return getConfigProperties().getString(keyPrefix + ".lockTimeUnit", "MILLISECONDS");
	}
	
	/**
	 * http api 调用日志接口
	 * @return
	 */
	public static boolean http_api_log() {
		return getConfigProperties().getBoolean("http.api.log",false);
	}
	
	
	/**
	 * caffine 缓存过期时间
	 * @return
	 */
	public static int caffine_expire_time() {
		return getConfigProperties().getInt("caffine.expire.time",10 * 60);
	}
	
	/**
	 * 缓存key 数量
	 * @return
	 */
	public static int caffine_maximum_size() {
		return getConfigProperties().getInt("caffine.maximum.size",1_000_000);
	}
	
	
	/**
	 * 服务器mvc 错误日志打印开关
	 * @return
	 */
	public static boolean mvc_advice_error_log() {
		//return getConfigProperties().getBoolean("mvc.advice.error.log", true);
		return true;
	}
	
	/**
	 * 是否开启 日志异常警告监控
	 * @return
	 */
	public static boolean log_warning_open() {
		return getConfigProperties().getBoolean("log.warning.open", false);
	}
	
	/**
	 * 监听通知邮件对象
	 * @return
	 */
	@SuppressWarnings("unchecked")
	public static Set<String> log_warning_mails(){
		
		String mails = getConfigProperties().getString("log.warning.mails","");
		
		if(!StringUtils.hasLength(mails)) {
			return default_set;
		}
		
		Object o = cache.getOrDefault(mails, null);
	
		if(o == null) {
			o = cache.computeIfAbsent(mails, (k)->{
				
				String[] classs = mails.split("[,]");
				
				Set<String> set = Sets.newConcurrentHashSet();
				
				for (int i = 0; i < classs.length; i++) {
					
					String str = classs[i];
					
					if(!StringUtils.hasLength(str)) {
						continue;
					}
					
					set.add(str);
				}
				
				return set;
			});
			
			if(o instanceof Set) {
				return (Set<String>)o;
			}
		}
		
		return (Set<String>)o;
	}
	

	/**
	 * 需要忽略的log 异常日志监听class
	 * @return
	 */
	@SuppressWarnings("unchecked")
	public static Set<String> log_warning_ignore_class(){
		
		String ignores = getConfigProperties().getString("log.warning.ignore.class",ServiceException.class.getSimpleName());
		
		if(!StringUtils.hasLength(ignores)) {
			return default_set;
		}
		
		Object o = cache.getOrDefault(ignores, null);
	
		if(o == null) {
			o = cache.computeIfAbsent(ignores, (k)->{
				
				String[] classs = ignores.split("[,]");
				
				Set<String> set = Sets.newConcurrentHashSet();
				
				for (int i = 0; i < classs.length; i++) {
					
					String str = classs[i];
					
					if(!StringUtils.hasLength(str)) {
						continue;
					}
					
					set.add(str);
				}
				
				return set;
			});
			
			if(o instanceof Set) {
				return (Set<String>)o;
			}
		}
		
		return (Set<String>)o;
	}
	

	public static String log_warning_mail_host() {
		return getConfigProperties().getString("log.warning.mail.host","smtp.qq.com");
	}
	public static int log_warning_mail_port() {
		return getConfigProperties().getInt("log.warning.mail.port",587);
	}
	public static String log_warning_mail_username() {
		return getConfigProperties().getString("log.warning.mail.username","xxxx@qq.com");
	}
	public static String log_warning_mail_password() {
		return getConfigProperties().getString("log.warning.mail.password","password");
	}
	public static boolean log_warning_mail_smtp_ssl_enable() {
		return getConfigProperties().getBoolean("log.warning.mail.smtp.ssl.enable",false);
	}
	
	/**
	 * 繁忙-同时要执行的任务个数超过这个值
	 * @return
	 */
	public static int busily_task_count() {
		return getConfigProperties().getInt("busily.task.count", 20);
	}
	
	public static long UserQueuedThreadPoolExecutor_keepAliveTime() {
		return  getConfigProperties().getLong("UserQueuedThreadPoolExecutor.keepAliveTime", 60);
	}
	
	public static TimeUnit UserQueuedThreadPoolExecutor_keepAliveTimeUnit() {
		return  TimeUnit.valueOf(getConfigProperties().getString("UserQueuedThreadPoolExecutor.keepAliveTimeUnit", "SECONDS"));
	}
	
	public static int UserQueuedThreadPoolExecutor_taskCapacity() {
		return  getConfigProperties().getInt("UserQueuedThreadPoolExecutor.taskCapacity", 60);
	}
	
	
	public static int net_maxMsgPackSize() {
		return 	getConfigProperties().getInt("net.maxMsgPackSize", 1024 * 10);
	}
	
	/**
	 * 线程执行记录
	 * @return
	 */
	public static boolean exec_log() {
		return getConfigProperties().getBoolean("exec.log", false);
	}
	
	public static int scoket_tcp_register_timeout() {
		return getConfigProperties().getInt("scoket.tcp.register.timeout", 3);
	}
	
	public static int netty_heartbeat_r_timeout() {
		return getConfigProperties().getInt("netty.heartbeat.r.timeout", 120);
	}
	
	public static int netty_heartbeat_w_timeout() {
		return getConfigProperties().getInt("netty.heartbeat.w.timeout", 120);
	}
	
	public static int netty_heartbeat_rw_timeout() {
		return getConfigProperties().getInt("netty.heartbeat.rw.timeout", 120);
	}

	
	/**
	 * tcp port 端口号
	 * @return
	 */
	public static int netty_tcp_port() {
		return getConfigProperties().getInt("netty.tcp.port",-1);
	}
	
	/**
	 * websocket 端口号
	 * @return
	 */
	public static int netty_websocket_port() {
		return getConfigProperties().getInt("netty.websocket.port",-1);
	}
	
	/**
	 * 获取应用名称
	 * @return
	 */
	public static String spring_application_name() {
		return getConfigProperties().getString(ServerConfigConstants.spring_application_name, "default_name");
	}
	
	/**
	 * 节点类型 
	 * @return
	 */
	public static String server_node_type() {
		return System.getProperty("server.node.type", "boss");
	}
	
	/**
	 * jvm redis 数据检测开关
	 * @return
	 */
	public static boolean jvm_redis_data_check(){
		return getConfigProperties().getBoolean("jvm.redis.data.check", false);
	}
	
	/**
	 * 是否支持 redis stream
	 * @return
	 */
	public static boolean redis_stream() {
		return getConfigProperties().getBoolean("redis.stream", true);
	}

	
	public static int slowly_mysqlRead() {
		return getConfigProperties().getInt("slowly.mysqlRead", 100);
	}

	public static int slowly_mysqlWrite() {
		return getConfigProperties().getInt("slowly.mysqlWrite", 200);
	}

	public static int slowly_mysqlExecute() {
		return getConfigProperties().getInt("slowly.mysqlExecute", 300);
	}
	/**
	 * tcp prot 端口号
	 * @return
	 */
	public static int http_port() {
		return getConfigProperties().getInt("server.port",-1);
	}
	
	
	/**
	 * 账号系统 uid 生成起始位置
	 * @return
	 */
	public static long account_uid_begin_number_id() {
		return getConfigProperties().getLong("account.uid.begin.number.id",1000000l);
	}
	
	/**
	 * 玩家id 起点
	 * @return
	 */
	public static long player_id_begin_number_id() {
		return getConfigProperties().getLong("player.id.begin.number.id",100000000l);
	}
	
	/**
	 * 起点
	 * @return
	 */
	public static long incr_id_begin_number_id() {
		return getConfigProperties().getLong("incr.id.begin.number.id",1000000l);
	}
	
	
	/**
	 * 账号密码登录是否开启
	 * @return
	 */
	public static boolean account_pwd_login() {
		return getConfigProperties().getBoolean("account.pwd.login", true);
	}
	
	/**
	 * 是否开启邮箱验证码登录
	 * @return
	 */
	public static boolean account_email_login() {
		return getConfigProperties().getBoolean("account.email.login", true);
	}
	
	
	/**
	 * 是否开启手机短信验证登录
	 * @return
	 */
	public static boolean account_phone_login() {
		return getConfigProperties().getBoolean("account.phone.login", true);
	}
	
	/**
	 * 是否需要实名制
	 * @return
	 */
	public static boolean open_real_name() {
		return getConfigProperties().getBoolean("open.real.name", true);
	}
	
	/**
	 * 验证身份证是否正确
	 * @return
	 */
	public static boolean vail_real_name() {
		return getConfigProperties().getBoolean("vail.real.name", false);
	}
	
	/**
	 * 是否需要绑定手机号
	 * @return
	 */
	public static boolean need_bind_phone() {
		return getConfigProperties().getBoolean("need.bind.phone", false);
	}
	
	/**
	 * sdk api 	地址
	 * @return
	 */
	public static String sdk_api_url() {
		return getConfigProperties().getString("sdk.api.url","http://127.0.0.1:7000");
	}
	
	/**
	 * 是否记录心跳
	 * @return
	 */
	public static boolean log_heart_beat_open() {
		return getConfigProperties().getBoolean("log.heart.beat.open",true);
	} 
	
	
	/**
	 * db 刷新
	 * @return
	 */
	public static boolean synchronizer_flush_open() {
		return getConfigProperties().getBoolean("synchronizer.flush.open", true);
	}
	
	
	
	/**
	 * 是否开启功能开关校验
	 * @return
	 */
	public static boolean game_server_open_func_verify() {
		return getConfigProperties().getBoolean("game.server.open.func.verify", true);
	}
	
	
	/**
	 * 秘籍开关
	 * @return
	 */
	public static boolean game_server_miji_open() {
		return getConfigProperties().getBoolean("game.server.miji.open", false);
	}
	
	
	/**
	 * 战斗日志打印开关
	 * @return
	 */
	public static boolean server_battle_log_open() {
		return getConfigProperties().getBoolean("server.battle.log.open", false);
	}
	
	
	/**
	 * 战斗日志打印开关
	 * @return
	 */
	public static boolean friend_search_from_db() {
		return getConfigProperties().getBoolean("friend.search.from.db", false);
	}
	/**
	 * 超登录 token
	 * @return
	 */
	public static String game_admin_login_token() {
		return getConfigProperties().getString("game.admin.login.token", "");
	}
	
	/**
	 * 指定服务器id
	 * @return
	 */
	public static int server_id_fixed() {
	
		return getConfigProperties().getInt("server.id.fixed", -1);
	}
	
	
	/**
	 * 抖音用户Token校验接口(CP服务端校验)
	 * @return
	 */
	public static String sdk_douyin_user_auth_url() {
		return getConfigProperties().getString("sdk.douyin.user.auth.url", "https://developer.toutiao.com/api/apps/v2/jscode2session");
	}
	
	/**
	 * 抖音SDK appid
	 * @return
	 */
	public static String sdk_douyin_app_id() {
		return getConfigProperties().getString("sdk.douyin.app.id", "ttcb3bbd865431348602");
	}
	/**
	 * 抖音SDK appid
	 * @return
	 */
	public static String sdk_douyin_secret() {
		return getConfigProperties().getString("sdk.douyin.secret", "d68da203a8549cbae13f5382933de2cc5bd2c293");
	}
	
	
	/**
	 * 微信用户Token校验接口(CP服务端校验)
	 * @return
	 */
	public static String sdk_wechat_user_auth_url() {
		return getConfigProperties().getString("sdk.wechat.user.auth.url", "https://api.weixin.qq.com/sns/jscode2session");
	}
	
	/**
	 * 微信SDK appid
	 * @return
	 */
	public static String sdk_wechat_app_id() {
		return getConfigProperties().getString("sdk.wechat.app.id", "wx6a174f7e85bd276c");
	}
	/**
	 * 微信SDK appid
	 * @return
	 */
	public static String sdk_wechat_secret() {
		return getConfigProperties().getString("sdk.wechat.secret", "6ca9b169bc91ebb39ae94e112ab6b474");
	}

	/**
	 * 快手用户Token校验接口(CP服务端校验)
	 * @return
	 */
	public static String sdk_kuaishou_user_auth_url() {
		return getConfigProperties().getString("sdk.kuaishou.user.auth.url", "https://open.kuaishou.com/game/minigame/jscode2session");
	}

	/**
	 * 快手SDK appid
	 * @return
	 */
	public static String sdk_kuaishou_app_id() {
		return getConfigProperties().getString("sdk.kuaishou.app.id", "ks674976996644062232");
	}
	/**
	 * 快手SDK secret
	 * @return
	 */
	public static String sdk_kuaishou_secret() {
		return getConfigProperties().getString("sdk.kuaishou.secret", "FbiKUV-kQyIIdlSXtcbLrg");
	}
	
	
	/**
	 * 爱玩用户Token校验接口(CP服务端校验)
	 * @return
	 */
	public static String sdk_aiwan_user_auth_url() {
		return getConfigProperties().getString("sdk.aiwan.user.auth.url", "https://api-sdk.essmicrogames.com/user/auth");
	}
	
	/**
	 * 爱玩SDK appid
	 * @return
	 */
	public static String sdk_aiwan_app_id() {
		return getConfigProperties().getString("sdk.aiwan.app.id", "");
	}
	
	/**
	 * 爱玩SDK app_key 
	 * @return
	 */
	public static String sdk_aiwan_app_key() {
		return getConfigProperties().getString("sdk.aiwan.app.key", "");
	}
	


	/**
	 * 爱玩SDK pay_key
	 * @return
	 */
	public static String sdk_aiwan_pay_key() {
		return getConfigProperties().getString("sdk.aiwan.pay.key", "");
	}
	
	/**
	 * 服务器公钥地址
	 * @return
	 */
	public static String server_public_key_path() {
		return getConfigProperties().getString("server.public.key.path", "D:/desktop/key1/publicKey.keystore");
		//return "D:/desktop/key1/publicKey.keystore";
	}
	
	/**
	 * 服务器私钥地址
	 * @return
	 */
	public static String server_private_key_path() {
		return getConfigProperties().getString("server.private.key.path", "D:/desktop/key1/privateKey.keystore");
		//return "D:/desktop/key1/privateKey.keystore";
	}
	
	
	/**
	 * 自动充值
	 * @return
	 */
	public static boolean game_server_gm_recharge_open() {
		return getConfigProperties().getBoolean("game.server.gm.recharge.open", false);
		//return false;
	}
	
	/**
	 * 战报记录全部
	 * @return
	 */
	public static boolean battle_record_all() {
		return getConfigProperties().getBoolean("battle.record.all", true);
	}
	
	/**
	 * 充值白名单
	 * @return
	 */
/*	public static String game_server_recharge_white() {
		return getConfigProperties().getString("game.server.recharge.white", "");
	}*/
	
	/**
	 * 渠道对应回调地址
	 * @param channel
	 * @return
	 */
	public static String game_pay_callback_url(String channel) {
		return getConfigProperties().getString(StringFormatUitls.format("game.pay.callback.url.{}", channel), "");
	}
	
	/**
	 * 礼包码服务地址
	 * @return
	 */
	public static String gift_api_url() {
		return getConfigProperties().getString("gift.api.url","");
	}
	
	
	/**
	 * ai 现场队列上限
	 * @return
	 */
	public static int ai_thread_size_max() {
		return getConfigProperties().getInt("ai.thread.size.max",30000);
	}
	
	
	/**
	 * ai 调度初始延迟
	 * @return
	 */
	public static int ai_schedule_initial_delay() {
		return getConfigProperties().getInt("ai.schedule.initial.delay",120);
	}
	
	
	/**
	 * ai 调度间隔
	 * @return
	 */
	public static int ai_schedule_delay() {
		return getConfigProperties().getInt("ai.schedule.delay",300);
	}
	
	
	/**
	 * ai 每批次跑多少个玩家
	 * @return
	 */
	public static int ai_schedule_player_num() {
		return getConfigProperties().getInt("ai.schedule.player.num",25);
	}
	
	/**
	 * ai 进程总数
	 * @return
	 */
	public static int ai_server_count() {
		return getConfigProperties().getInt("ai.server.count", 1);
	}
	
	
	/**
	 * ai 当前进程取模
	 * @return
	 */
	public static int ai_server_count_mod() {
		return getConfigProperties().getInt("ai.server.count.mod", 0);
	}
	
	
 
	/**
	 * 限流
	 * @return
	 */
	public static boolean message_rate_limiter() {
		return getConfigProperties().getBoolean("message.rate.limiter", true);
	}
	
	
	/**
	 * 使用礼包码接口
	 * @return
	 */
	public static String gift_api_use_gift_code() {
		return getConfigProperties().getString("gift.api.use.gift.code","http://192.168.10.11:7002/gift/useGiftCode");
	}
	
	
	/**
	 * 提审服务器id设置
	 * @return
	 */
	public static int audit_server_id() {
		return getConfigProperties().getInt("audit.server.id", 0);
	}
	
	/**
	 * 提审版本号
	 * @return
	 */ 
	public static String aduit_client_version() {
		return getConfigProperties().getString("audit.client.version", "");
	}

	/**
	 * 游戏服务器异步登录开关
	 */
	public static boolean game_server_login_async() {
		return getConfigProperties().getBoolean("game.server.login.async", false);
	}

	/**
	 * 一人成服
	 */
	public static boolean game_one_person_one_server() {
		return getConfigProperties().getBoolean("game.one.person.one.server", true);
	}

	
	/**
	 * 爱玩数据上报Key
	 *
	 */
	public static String key_aiwan_data_report() {
		return getConfigProperties().getString("key.aiwan.data.report", "");
	}

	/**
	 * 爱玩数据上报地址
	 */
	public static String url_aiwan_data_report() {
		return getConfigProperties().getString("url.aiwan.data.report", "");
	}

	/**
	 * 项目别名
	 */
	public static String alias_aiwan_data_report() {
		return getConfigProperties().getString("alias.aiwan.data.report", "");
	}

	/**
	 * 爱玩玩家信息上报url
	 */
	public static String aiwan_player_data_report_url() {
		return getConfigProperties().getString("aiwan.player.data.report.url", "");
	}

	/**
	 * 数据上报开关
	 */
	public static boolean aiwan_data_report() {
		return getConfigProperties().getBoolean("aiwan.data.report", false);
	}

	/**
	 * 用来判断玩家是否跳过引导
	 */
	public static int guide_complete_id() {
		return getConfigProperties().getInt("guide.complete.id",1000);
	}

	/**
	 * 引导Id
	 */
	public static int guide_id() {
		return getConfigProperties().getInt("guide.id",0);
	}

	/**
	 * boss导入玩家数据
	 * @return
	 */
	public static boolean boss_import_player_data(){
		return getConfigProperties().getBoolean("boss.import.player.data",false);
	}

}
